using System;

namespace MessagingWPF.Infrastructure
{
	/// <summary>
	/// A publishing subscription manager.
	/// </summary>
	public interface IPubSub : ISubscriptionManager
	{
		/// <summary>
		/// Publishes the specified message.
		/// </summary>
		/// <param name="message">The message.</param>
		/// <exception cref="ArgumentNullException">
		/// Thrown when <paramref name="message"/> is <c>null</c>.
		/// </exception>
		/// <remarks>The message will only be sent if subscribers for it are present.</remarks>
		void Publish(object message);
	}
}